projects
/
gtk4.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
40dbb2d
)
tests/testcairo.c: Use accessor functions to access GtkWidget
author
Javier Jardón
<jjardon@gnome.org>
Sun, 15 Aug 2010 22:34:48 +0000
(
00:34
+0200)
committer
Javier Jardón
<jjardon@gnome.org>
Sun, 22 Aug 2010 16:29:42 +0000
(18:29 +0200)
tests/testcairo.c
patch
|
blob
|
history
diff --git
a/tests/testcairo.c
b/tests/testcairo.c
index b2a232b0265da6498c08287789c273c6aed6ebbb..dc3a27cfc26d4d48c26f278cdff5f374c961dff2 100644
(file)
--- a/
tests/testcairo.c
+++ b/
tests/testcairo.c
@@
-195,11
+195,13
@@
on_expose_event (GtkWidget *widget,
GdkEventExpose *event,
gpointer data)
{
+ GtkAllocation allocation;
cairo_t *cr;
- cr = gdk_cairo_create (
widget->window
);
+ cr = gdk_cairo_create (
gtk_widget_get_window (widget)
);
- draw (cr, widget->allocation.width, widget->allocation.height);
+ gtk_widget_get_allocation (widget, &allocation);
+ draw (cr, allocation.width, allocation.height);
cairo_destroy (cr);